/* 
 * File:   LoginController.h
 * Author: user
 *
 * Created on July 29, 2014, 9:54 PM
 */

#ifndef LOGINCONTROLLER_H
#define	LOGINCONTROLLER_H

#include <string>
#include <stdio.h>

using namespace std;

class LoginController {
public:
    LoginController();
    LoginController(const LoginController& orig);
    virtual ~LoginController();
    
    //-1 = invalid, 0= admin, 1 lecturer, 2=student
    int verifyLogin(string loginID,string pw,int userType, string& userID,string& createBy); 
    static void processPassword(string& password);
    
private:
    bool executeVerify(const char* sql);
    static int authenticate (void *NotUsed, int argc, char **argv, char **azColName); 
    

};

#endif	/* LOGINCONTROLLER_H */

